export const state = () => ({
  hospitalOrderSkuSummary: [] // 院端新建结算单
})

export const mutations = {
  // 更新院端新建结算单
  updateSkuSummary (state, SummaryItem) {
    state.hospitalOrderSkuSummary.push(SummaryItem)
  },
  // 重置院端新建结算单
  resetSkuSummary (state, arr) {
    state.hospitalOrderSkuSummary = arr
  },
  changeOneObjNum (state, data) {
    state.hospitalOrderSkuSummary[data.index].selectedAmount = data.num
  }
}

export const actions = {
  changeArrList ({ state, commit }, data) {
    commit('changeOneObjNum', data)
  }
}
